

class Car(object):
    def __init__(self, color, csfe):
        self.color = color
        self.csfe = csfe

    def introduce(self):
        print(f"我是一辆{self.color}的车，我的百公里油耗是{self.csfe}L")


class Racing_Car(Car):
    def __init__(self, color, csfe, acceleration_time, max_speed):
        super().__init__(color, csfe)
        self.acceleration_time = acceleration_time
        self.max_speed = max_speed

    def introduce(self):
        print(f'''我是一辆{self.color}的车， 我的百公里油耗是{self.csfe}L，加速时间是{self.acceleration_time}s，最大速度是{self.max_speed}km/s''')


class Bus(Car):
    def __init__(self, color, csfe, passenger_capacity):
        super().__init__(color, csfe)
        self.passenger_capacity = passenger_capacity

    def introduce(self):
        print(f'''我是一辆{self.color}的车， 我的百公里油耗是{self.csfe}L，载客人数是{self.passenger_capacity}''')

def introduce(object:Car, number):
    while(number>=1):
        object.introduce()
        number -= 1

if '__main__' == __name__:
    car1 = Car('红色', 10)
    introduce(car1, 5)
